Bad sector

A bad sector is a sector on a computer's disk drive or flash memory that cannot be used due to permanent damage (or an OS inability to successfully access it), such as physical damage to the disk surface (or sometimes sectors being stuck in a magnetic or digital state that cannot be reversed) or failed flash memory transistors. It is usually detected by a disk utility software such as CHKDSK or SCANDISK on Microsoft systems, or badblocks on Unix-like systems. When found, these programs may mark the sectors unusable (all file systems contain provisions for bad-sector marks) and the operating system skips them in the future.

A modern hard drive comes with many spare sectors . When a sector is found to be bad by the firmware of a disk controller, the disk controller remaps the logical sector to a different physical sector. In the normal operation of a hard drive, the detection and remapping of bad sectors should take place in a manner transparent to the rest of the system. There are two types of remapping by disk hardware; P-LIST (Mapping during factory production tests) and G-LIST (Mapping during consumer usage by disk microcode) [1]. There are a variety of utilities that can read the SMART information to tell how many sectors have been reallocated, and how many spare sectors the drive may still have.[2]

Typically, automatic remapping of sectors only happens when a sector is written to. The logic behind this is presumably that even if a sector cannot be read normally, it may still be readable with data recovery methods. However, if a drive knows that a sector is bad and the drive's controller receives a command to write over it, it will not reuse that sector and will instead remap it to one of its spare-sector regions. This may be the reason why hard disks continue to have sector errors (mostly disk controller timeouts) until all the bad sectors are remapped; typically this is accomplished by writing zeros to the entire drive. See the SMART attribute number 197 ("Current Pending Sector Count") for more information.[3]

Contents

Intentional bad sectors

Some CD and DVD copy protection schemes such as ARccOS use deliberately corrupt sectors in specific areas of the disc that are not accessed by most normal CD or DVD players. These bad sectors throw off copying programs because most copying programs read the entire disc, including these corrupt areas that a player would not access.

See Also

References

External links